import request from '@/utils/request'
function getUrl(url) { return '/api/' + url }

//joinChannel
export function joinChannel(data) {
    return request({
        url: getUrl("admin/rtc/joinChannel                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         "),
        method: 'post',
        data
    })
}
//本地预览
export function  startPreview(data) {
    return request({
        url: getUrl("admin/rtc/joinChannel"),
        method: 'post',
        data
    })
}

//拉取人员
export function  pullPerson(data) {
    return request({
        url: getUrl("admin/rtc/pullPerson"),
        method: 'post',
        data
    })
}

//关闭通道
export function  deleteChannel(data) {
    return request({
        url: getUrl("admin/rtc/deleteChannel"),
        method: 'post',
        data
    })
}

//joinChannel
export function launchFireVideo(data) {
    return request({
        url: getUrl("admin/fireInfo/launchFireVideo                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         "),
        method: 'post',
        data
    })
}


export function callMaintenancePerson(data) {
    return request({
        url: getUrl("admin/rtc/callMaintenancePerson                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         "),
        method: 'post',
        data
    })
}